package service;

import model.Hall;

import java.util.*;

public class HallService {
    private List<Hall> halls = new ArrayList<>();

    public HallService() {
        halls.add(new Hall("黄金厅", 8, 10));
        halls.add(new Hall("白银厅", 10, 12));
        halls.add(new Hall("翡翠厅", 7, 8));
        halls.add(new Hall("钻石厅", 7, 8));
        halls.add(new Hall("宝石厅", 8, 9));
    }

    public List<Hall> getHalls() {
        return halls;
    }

    public Hall getHallByName(String name) {
        for (Hall h : halls) {
            if (h.getName().equals(name)) return h;
        }
        return null;
    }
}